/****************************************************************************/
/* File: scs-clock.h                                                        */
/* Desc: Specification file for the core clock type                         */
/* Created: 2014-11-10                                                      */
/* Revised: 2014-11-13                                                      */
/* Authors: Sterling P. de Mille                                            */
/****************************************************************************/

// include once
#ifndef _SCS_CLOCK_H_
#define _SCS_CLOCK_H_

// core data types
#include "scs-types.h"

// SDL framework
#include <SDL/SDL.h>
// SDL clock support
#include <SDL/SDL_timer.h>

// assert support
#include <assert.h>

// core clock type
class SCSclock
{
protected:

	SCSint32u		m_iCurrentTicks;
	SCSint32u		m_iPreviousTicks;
	SCSint32u		m_iDeltaTicks;

	// singleton object
	static SCSclock* m_pkSingleton;

public:

 	// constructors
 	SCSclock ();
 	 // destructor
 	~SCSclock ();

	void Update ();
	void Reset ();

	SCSfloat GetDT ();
	SCSfloat GetFPS ();

	// singleton access
	static SCSclock* Singleton ();
};

#endif // _SCS_CLOCK_H_
